﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using ViewModels.CommonVM;

namespace HinokyWeb.Common
{
    public class ConvertTo
    {
        public static string BackLogTypeText(string value)
        {
            switch (value)
            {
                case "1":
                    return "To-Be";
                case "2":
                    return "Defact";
                default:
                    return string.Empty;
            }
        }

        public static string BackLogCategoryText(string value)
        {
            var list = new MenuObjVM().MenuList;
            return list.FirstOrDefault(s => s.Key == value).Value;
        }

        public static string BackLogStateText(string value)
        {
            switch (value)
            {
                case "1":
                    return "New";
                case "2":
                    return "Progressing";
                case "3":
                    return "Complete";
                case "4":
                    return "ReIssue";
                case "5":
                    return "Hold Off";
                default:
                    return string.Empty;
            }
        }
    }
}